<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="zh">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=11"/>
<meta name="generator" content="Doxygen 1.11.0"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>cppMISC: include/designM/strategy.hpp 源文件</title>
<link href="../../tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="../../jquery.js"></script>
<script type="text/javascript" src="../../dynsections.js"></script>
<script type="text/javascript" src="../../clipboard.js"></script>
<link href="../../navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="../../resize.js"></script>
<script type="text/javascript" src="../../cookie.js"></script>
<link href="../../search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="../../search/searchdata.js"></script>
<script type="text/javascript" src="../../search/search.js"></script>
<script type="text/javascript" src="../../darkmode_toggle.js"></script>
<link href="../../doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr id="projectrow">
  <td id="projectalign">
   <div id="projectname">cppMISC<span id="projectnumber">&#160;v1.1</span>
   </div>
   <div id="projectbrief">cppMisc 文档系统</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- 制作者 Doxygen 1.11.0 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
var searchBox = new SearchBox("searchBox", "../../search/",'.html');
/* @license-end */
</script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
$(function() { codefold.init(1); });
/* @license-end */
</script>
<script type="text/javascript" src="../../menudata.js"></script>
<script type="text/javascript" src="../../menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
$(function() {
  initMenu('../../',true,false,'search.php','搜索',false);
  $(function() { init_search(); });
});
/* @license-end */
</script>
<div id="main-nav"></div>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
$(function(){ initResizable(false); });
/* @license-end */
</script>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<div id="MSearchResults">
<div class="SRPage">
<div id="SRIndex">
<div id="SRResults"></div>
<div class="SRStatus" id="Loading">载入中...</div>
<div class="SRStatus" id="Searching">搜索中...</div>
<div class="SRStatus" id="NoMatches">未找到</div>
</div>
</div>
</div>
</div>

<div id="nav-path" class="navpath">
  <ul>
<li class="navelem"><a class="el" href="../../dir_d44c64559bbebec7f509842c48db8b23.html">include</a></li><li class="navelem"><a class="el" href="../../dir_7815f4a69fa470e020068bb120d080ef.html">designM</a></li>  </ul>
</div>
</div><!-- top -->
<div id="doc-content">
<div class="header">
  <div class="headertitle"><div class="title">strategy.hpp</div></div>
</div><!--header-->
<div class="contents">
<a href="../../d2/d62/strategy_8hpp.html">浏览该文件的文档.</a><div class="fragment"><div class="line"><a id="l00001" name="l00001"></a><span class="lineno">    1</span> </div>
<div class="line"><a id="l00008" name="l00008"></a><span class="lineno">    8</span><span class="preprocessor">#pragma once</span></div>
<div class="line"><a id="l00009" name="l00009"></a><span class="lineno">    9</span> </div>
<div class="line"><a id="l00010" name="l00010"></a><span class="lineno">   10</span><span class="preprocessor">#include &lt;type_traits&gt;</span></div>
<div class="line"><a id="l00011" name="l00011"></a><span class="lineno">   11</span><span class="preprocessor">#include &lt;unordered_map&gt;</span></div>
<div class="line"><a id="l00012" name="l00012"></a><span class="lineno">   12</span><span class="preprocessor">#include &lt;iostream&gt;</span></div>
<div class="line"><a id="l00013" name="l00013"></a><span class="lineno">   13</span><span class="preprocessor">#include &lt;functional&gt;</span></div>
<div class="line"><a id="l00014" name="l00014"></a><span class="lineno">   14</span><span class="preprocessor">#include &lt;cstddef&gt;</span></div>
<div class="line"><a id="l00015" name="l00015"></a><span class="lineno">   15</span> </div>
<div class="line"><a id="l00016" name="l00016"></a><span class="lineno">   16</span><span class="keyword">namespace </span><a class="code hl_namespace" href="../../df/d8d/namespacewheels.html">wheels</a></div>
<div class="line"><a id="l00017" name="l00017"></a><span class="lineno">   17</span>{</div>
<div class="line"><a id="l00024" name="l00024"></a><span class="lineno">   24</span>    <span class="keyword">namespace </span>dm</div>
<div class="line"><a id="l00025" name="l00025"></a><span class="lineno">   25</span>    {</div>
<div class="line"><a id="l00026" name="l00026"></a><span class="lineno"><a class="line" href="../../d0/db2/structwheels_1_1dm_1_1strategy.html">   26</a></span>        <span class="keyword">template</span>&lt; <span class="keyword">typename</span> keyType , <span class="keyword">typename</span> funcType &gt; <span class="keyword">struct </span><a class="code hl_struct" href="../../d0/db2/structwheels_1_1dm_1_1strategy.html">strategy</a>{};</div>
<div class="line"><a id="l00027" name="l00027"></a><span class="lineno">   27</span>        </div>
<div class="line"><a id="l00028" name="l00028"></a><span class="lineno">   28</span>        <span class="keyword">template</span>&lt; <span class="keyword">typename</span> keyType , <span class="keyword">typename</span> Ret , <span class="keyword">typename</span> ...Args &gt;</div>
<div class="foldopen" id="foldopen00029" data-start="{" data-end="};">
<div class="line"><a id="l00029" name="l00029"></a><span class="lineno"><a class="line" href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html">   29</a></span>        <span class="keyword">class </span><a class="code hl_struct" href="../../d0/db2/structwheels_1_1dm_1_1strategy.html">strategy</a>&lt; keyType , <a class="code hl_namespace" href="../../d8/dcc/namespacestd.html">std</a>::function&lt; Ret (Args...) &gt; &gt;{</div>
<div class="line"><a id="l00030" name="l00030"></a><span class="lineno">   30</span>        <span class="keyword">public</span>:</div>
<div class="line"><a id="l00031" name="l00031"></a><span class="lineno"><a class="line" href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#ae6a943aa1f434aee4097956b23bd182d">   31</a></span>            <span class="keyword">using </span><a class="code hl_typedef" href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#ae6a943aa1f434aee4097956b23bd182d">callee_type</a> = std::function&lt; Ret (Args...) &gt;;</div>
<div class="line"><a id="l00032" name="l00032"></a><span class="lineno"><a class="line" href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#ab6e495a6802ef53134b4e0bd0f64b77c">   32</a></span>            <span class="keyword">using </span><a class="code hl_typedef" href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#ab6e495a6802ef53134b4e0bd0f64b77c">iterator</a>    = <span class="keyword">typename</span> std::unordered_map&lt; keyType , callee_type &gt;::iterator;</div>
<div class="line"><a id="l00033" name="l00033"></a><span class="lineno">   33</span>        <span class="keyword">protected</span>:</div>
<div class="line"><a id="l00034" name="l00034"></a><span class="lineno"><a class="line" href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#aeb05f9e8f1d24d67ae08eb1a8bc2b0ec">   34</a></span>            std::unordered_map&lt; keyType , callee_type &gt;    <a class="code hl_variable" href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#aeb05f9e8f1d24d67ae08eb1a8bc2b0ec">__m_strates</a>;</div>
<div class="line"><a id="l00035" name="l00035"></a><span class="lineno">   35</span>        <span class="keyword">public</span>:</div>
<div class="line"><a id="l00036" name="l00036"></a><span class="lineno"><a class="line" href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#aa5a09953913fdf5e562623497373613e">   36</a></span>            <a class="code hl_function" href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#aa5a09953913fdf5e562623497373613e">strategy</a>(){}</div>
<div class="line"><a id="l00037" name="l00037"></a><span class="lineno"><a class="line" href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#a2bddb9ebfc06f5fe85ec3a72c63e6272">   37</a></span>            <span class="keyword">virtual</span> <a class="code hl_function" href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#a2bddb9ebfc06f5fe85ec3a72c63e6272">~strategy</a>(){}</div>
<div class="line"><a id="l00043" name="l00043"></a><span class="lineno">   43</span>            <span class="keyword">template</span>&lt;<span class="keyword">typename</span> Funct_t &gt;</div>
<div class="foldopen" id="foldopen00044" data-start="{" data-end="}">
<div class="line"><a id="l00044" name="l00044"></a><span class="lineno"><a class="line" href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#a395457ca646efff17484574a651aeace">   44</a></span>            <span class="keywordtype">bool</span> <a class="code hl_function" href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#a395457ca646efff17484574a651aeace">add</a>( <span class="keyword">const</span> keyType&amp; key , Funct_t&amp;&amp; callFn ){</div>
<div class="line"><a id="l00045" name="l00045"></a><span class="lineno">   45</span>                <span class="keyword">auto</span> it = __m_strates.find( key );</div>
<div class="line"><a id="l00046" name="l00046"></a><span class="lineno">   46</span>                <span class="keywordflow">if</span>( it == __m_strates.end() ){</div>
<div class="line"><a id="l00047" name="l00047"></a><span class="lineno">   47</span>                    __m_strates.insert( std::make_pair( key , std::forward&lt;Funct_t&gt;( callFn ) ) );</div>
<div class="line"><a id="l00048" name="l00048"></a><span class="lineno">   48</span>                    <span class="keywordflow">return</span> <span class="keyword">true</span>;</div>
<div class="line"><a id="l00049" name="l00049"></a><span class="lineno">   49</span>                }</div>
<div class="line"><a id="l00050" name="l00050"></a><span class="lineno">   50</span> </div>
<div class="line"><a id="l00051" name="l00051"></a><span class="lineno">   51</span>                <span class="keywordflow">return</span> <span class="keyword">false</span>;</div>
<div class="line"><a id="l00052" name="l00052"></a><span class="lineno">   52</span>            }</div>
</div>
<div class="foldopen" id="foldopen00056" data-start="{" data-end="}">
<div class="line"><a id="l00056" name="l00056"></a><span class="lineno"><a class="line" href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#a1f852e13f712172a48657dd4b1016834">   56</a></span>            <span class="keywordtype">bool</span> <a class="code hl_function" href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#a1f852e13f712172a48657dd4b1016834">erase</a>( <span class="keyword">const</span> keyType&amp; key ){</div>
<div class="line"><a id="l00057" name="l00057"></a><span class="lineno">   57</span>                <span class="keyword">auto</span> it = __m_strates.find( key );</div>
<div class="line"><a id="l00058" name="l00058"></a><span class="lineno">   58</span>                <span class="keywordflow">if</span>( it != __m_strates.end() ){</div>
<div class="line"><a id="l00059" name="l00059"></a><span class="lineno">   59</span>                    __m_strates.erase( it );</div>
<div class="line"><a id="l00060" name="l00060"></a><span class="lineno">   60</span>                    <span class="keywordflow">return</span> <span class="keyword">true</span>;</div>
<div class="line"><a id="l00061" name="l00061"></a><span class="lineno">   61</span>                }</div>
<div class="line"><a id="l00062" name="l00062"></a><span class="lineno">   62</span> </div>
<div class="line"><a id="l00063" name="l00063"></a><span class="lineno">   63</span>                <span class="keywordflow">return</span> <span class="keyword">false</span>;</div>
<div class="line"><a id="l00064" name="l00064"></a><span class="lineno">   64</span>            }</div>
</div>
<div class="line"><a id="l00068" name="l00068"></a><span class="lineno"><a class="line" href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#a60a0b9e2d7d3f150a718106e84cf8ed9">   68</a></span>            <span class="keywordtype">void</span> <a class="code hl_function" href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#a60a0b9e2d7d3f150a718106e84cf8ed9">clear</a>(){ __m_strates.erase( __m_strates.begin() , __m_strates.end() ); }</div>
<div class="line"><a id="l00072" name="l00072"></a><span class="lineno"><a class="line" href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#a0afd53d5f41ad4f440af393a39548ab0">   72</a></span>            <span class="keywordtype">size_t</span> <a class="code hl_function" href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#a0afd53d5f41ad4f440af393a39548ab0">count</a>(){ <span class="keywordflow">return</span> __m_strates.size(); }</div>
<div class="line"><a id="l00073" name="l00073"></a><span class="lineno">   73</span>            </div>
<div class="line"><a id="l00077" name="l00077"></a><span class="lineno">   77</span>            <span class="keyword">template</span>&lt; <span class="keyword">typename</span> ...Params &gt;</div>
<div class="foldopen" id="foldopen00078" data-start="{" data-end="}">
<div class="line"><a id="l00078" name="l00078"></a><span class="lineno"><a class="line" href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#ad1cc34a4b5c306c0d9ab249c5ddf5c6b">   78</a></span>            <span class="keywordtype">void</span> <a class="code hl_function" href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#ad1cc34a4b5c306c0d9ab249c5ddf5c6b">call_each</a>( Params&amp;&amp;... args ){</div>
<div class="line"><a id="l00079" name="l00079"></a><span class="lineno">   79</span>                <span class="keywordflow">for</span>( <span class="keyword">auto</span> it = __m_strates.begin(); it != __m_strates.end(); ++it ){</div>
<div class="line"><a id="l00080" name="l00080"></a><span class="lineno">   80</span>                    it-&gt;second( std::forward&lt;Args&gt;(args)... );</div>
<div class="line"><a id="l00081" name="l00081"></a><span class="lineno">   81</span>                }</div>
<div class="line"><a id="l00082" name="l00082"></a><span class="lineno">   82</span>            }</div>
</div>
<div class="line"><a id="l00089" name="l00089"></a><span class="lineno">   89</span>            <span class="keyword">template</span>&lt; <span class="keyword">typename</span> ...Params &gt;</div>
<div class="foldopen" id="foldopen00090" data-start="{" data-end="}">
<div class="line"><a id="l00090" name="l00090"></a><span class="lineno"><a class="line" href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#a9ff09bb0d9c2bca5ff2969cbacae3a10">   90</a></span>            Ret <a class="code hl_function" href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#a9ff09bb0d9c2bca5ff2969cbacae3a10">call</a>( <span class="keyword">const</span> keyType&amp; key , Params&amp;&amp;... args ){</div>
<div class="line"><a id="l00091" name="l00091"></a><span class="lineno">   91</span>                <span class="keyword">auto</span> it = __m_strates.find( key );</div>
<div class="line"><a id="l00092" name="l00092"></a><span class="lineno">   92</span>                <span class="keywordflow">if</span>( it != __m_strates.end() ){</div>
<div class="line"><a id="l00093" name="l00093"></a><span class="lineno">   93</span>                    <span class="keywordflow">return</span> it-&gt;second(std::forward&lt;Params&gt;(args)...);</div>
<div class="line"><a id="l00094" name="l00094"></a><span class="lineno">   94</span>                }</div>
<div class="line"><a id="l00095" name="l00095"></a><span class="lineno">   95</span>                std::cout &lt;&lt; <span class="stringliteral">&quot;Can not find strategy key&quot;</span> &lt;&lt; std::endl;</div>
<div class="line"><a id="l00096" name="l00096"></a><span class="lineno">   96</span>                <span class="keywordflow">throw</span> std::runtime_error( <span class="stringliteral">&quot;branch is not exist&quot;</span> );</div>
<div class="line"><a id="l00097" name="l00097"></a><span class="lineno">   97</span>            }</div>
</div>
<div class="line"><a id="l00098" name="l00098"></a><span class="lineno">   98</span>        };</div>
</div>
<div class="line"><a id="l00099" name="l00099"></a><span class="lineno">   99</span>        </div>
<div class="line"><a id="l00100" name="l00100"></a><span class="lineno">  100</span>        <span class="comment">// 用来支持从普通函数指针来推导接口类型</span></div>
<div class="line"><a id="l00101" name="l00101"></a><span class="lineno">  101</span>        <span class="keyword">template</span>&lt; <span class="keyword">typename</span> keyType , <span class="keyword">typename</span> Ret , <span class="keyword">typename</span> ...Args &gt;</div>
<div class="line"><a id="l00102" name="l00102"></a><span class="lineno"><a class="line" href="../../d9/d92/classwheels_1_1dm_1_1strategy_3_01key_type_00_01_ret_07_args_8_8_8_08_01_4.html">  102</a></span>        <span class="keyword">class </span><a class="code hl_struct" href="../../d0/db2/structwheels_1_1dm_1_1strategy.html">strategy</a>&lt; keyType , Ret (Args...) &gt; : <span class="keyword">public</span> <a class="code hl_struct" href="../../d0/db2/structwheels_1_1dm_1_1strategy.html">strategy</a>&lt;keyType , std::function&lt;Ret (Args...)&gt; &gt;{};</div>
<div class="line"><a id="l00103" name="l00103"></a><span class="lineno">  103</span>        </div>
<div class="line"><a id="l00104" name="l00104"></a><span class="lineno">  104</span>        <span class="comment">// 用来支持从类成员函数对到接口类型</span></div>
<div class="line"><a id="l00105" name="l00105"></a><span class="lineno">  105</span>        <span class="keyword">template</span>&lt;<span class="keyword">typename</span> keyType , <span class="keyword">typename</span> <span class="keyword">class</span>Type , <span class="keyword">typename</span> funcType &gt;</div>
<div class="line"><a id="l00106" name="l00106"></a><span class="lineno"><a class="line" href="../../d7/d86/classwheels_1_1dm_1_1strategy_3_01key_type_00_01func_type_01class_type_1_1_5_01_4.html">  106</a></span>        <span class="keyword">class </span><a class="code hl_struct" href="../../d0/db2/structwheels_1_1dm_1_1strategy.html">strategy</a>&lt; keyType , funcType classType::*&gt; : <span class="keyword">public</span> <a class="code hl_struct" href="../../d0/db2/structwheels_1_1dm_1_1strategy.html">strategy</a>&lt; keyType , std::function&lt; funcType &gt; &gt;{};</div>
<div class="line"><a id="l00107" name="l00107"></a><span class="lineno">  107</span>    }</div>
<div class="line"><a id="l00108" name="l00108"></a><span class="lineno">  108</span>}</div>
<div class="ttc" id="aclasswheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4_html_a0afd53d5f41ad4f440af393a39548ab0"><div class="ttname"><a href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#a0afd53d5f41ad4f440af393a39548ab0">wheels::dm::strategy&lt; keyType, std::function&lt; Ret(Args...) &gt; &gt;::count</a></div><div class="ttdeci">size_t count()</div><div class="ttdoc">读取记录数量</div><div class="ttdef"><b>定义</b> <a href="#l00072">strategy.hpp:72</a></div></div>
<div class="ttc" id="aclasswheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4_html_a1f852e13f712172a48657dd4b1016834"><div class="ttname"><a href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#a1f852e13f712172a48657dd4b1016834">wheels::dm::strategy&lt; keyType, std::function&lt; Ret(Args...) &gt; &gt;::erase</a></div><div class="ttdeci">bool erase(const keyType &amp;key)</div><div class="ttdoc">移除算法操作</div><div class="ttdef"><b>定义</b> <a href="#l00056">strategy.hpp:56</a></div></div>
<div class="ttc" id="aclasswheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4_html_a2bddb9ebfc06f5fe85ec3a72c63e6272"><div class="ttname"><a href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#a2bddb9ebfc06f5fe85ec3a72c63e6272">wheels::dm::strategy&lt; keyType, std::function&lt; Ret(Args...) &gt; &gt;::~strategy</a></div><div class="ttdeci">virtual ~strategy()</div><div class="ttdef"><b>定义</b> <a href="#l00037">strategy.hpp:37</a></div></div>
<div class="ttc" id="aclasswheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4_html_a395457ca646efff17484574a651aeace"><div class="ttname"><a href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#a395457ca646efff17484574a651aeace">wheels::dm::strategy&lt; keyType, std::function&lt; Ret(Args...) &gt; &gt;::add</a></div><div class="ttdeci">bool add(const keyType &amp;key, Funct_t &amp;&amp;callFn)</div><div class="ttdoc">添加算法操作</div><div class="ttdef"><b>定义</b> <a href="#l00044">strategy.hpp:44</a></div></div>
<div class="ttc" id="aclasswheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4_html_a60a0b9e2d7d3f150a718106e84cf8ed9"><div class="ttname"><a href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#a60a0b9e2d7d3f150a718106e84cf8ed9">wheels::dm::strategy&lt; keyType, std::function&lt; Ret(Args...) &gt; &gt;::clear</a></div><div class="ttdeci">void clear()</div><div class="ttdoc">清理记录</div><div class="ttdef"><b>定义</b> <a href="#l00068">strategy.hpp:68</a></div></div>
<div class="ttc" id="aclasswheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4_html_a9ff09bb0d9c2bca5ff2969cbacae3a10"><div class="ttname"><a href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#a9ff09bb0d9c2bca5ff2969cbacae3a10">wheels::dm::strategy&lt; keyType, std::function&lt; Ret(Args...) &gt; &gt;::call</a></div><div class="ttdeci">Ret call(const keyType &amp;key, Params &amp;&amp;... args)</div><div class="ttdoc">执行算法操作</div><div class="ttdef"><b>定义</b> <a href="#l00090">strategy.hpp:90</a></div></div>
<div class="ttc" id="aclasswheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4_html_aa5a09953913fdf5e562623497373613e"><div class="ttname"><a href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#aa5a09953913fdf5e562623497373613e">wheels::dm::strategy&lt; keyType, std::function&lt; Ret(Args...) &gt; &gt;::strategy</a></div><div class="ttdeci">strategy()</div><div class="ttdef"><b>定义</b> <a href="#l00036">strategy.hpp:36</a></div></div>
<div class="ttc" id="aclasswheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4_html_ab6e495a6802ef53134b4e0bd0f64b77c"><div class="ttname"><a href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#ab6e495a6802ef53134b4e0bd0f64b77c">wheels::dm::strategy&lt; keyType, std::function&lt; Ret(Args...) &gt; &gt;::iterator</a></div><div class="ttdeci">typename std::unordered_map&lt; keyType, callee_type &gt;::iterator iterator</div><div class="ttdef"><b>定义</b> <a href="#l00032">strategy.hpp:32</a></div></div>
<div class="ttc" id="aclasswheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4_html_ad1cc34a4b5c306c0d9ab249c5ddf5c6b"><div class="ttname"><a href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#ad1cc34a4b5c306c0d9ab249c5ddf5c6b">wheels::dm::strategy&lt; keyType, std::function&lt; Ret(Args...) &gt; &gt;::call_each</a></div><div class="ttdeci">void call_each(Params &amp;&amp;... args)</div><div class="ttdoc">针对所有的内容执行一次</div><div class="ttdef"><b>定义</b> <a href="#l00078">strategy.hpp:78</a></div></div>
<div class="ttc" id="aclasswheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4_html_ae6a943aa1f434aee4097956b23bd182d"><div class="ttname"><a href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#ae6a943aa1f434aee4097956b23bd182d">wheels::dm::strategy&lt; keyType, std::function&lt; Ret(Args...) &gt; &gt;::callee_type</a></div><div class="ttdeci">std::function&lt; Ret(Args...) &gt; callee_type</div><div class="ttdef"><b>定义</b> <a href="#l00031">strategy.hpp:31</a></div></div>
<div class="ttc" id="aclasswheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4_html_aeb05f9e8f1d24d67ae08eb1a8bc2b0ec"><div class="ttname"><a href="../../d4/d5f/classwheels_1_1dm_1_1strategy_3_01key_type_00_01std_1_1function_3_01_ret_07_args_8_8_8_08_01_4_01_4.html#aeb05f9e8f1d24d67ae08eb1a8bc2b0ec">wheels::dm::strategy&lt; keyType, std::function&lt; Ret(Args...) &gt; &gt;::__m_strates</a></div><div class="ttdeci">std::unordered_map&lt; keyType, callee_type &gt; __m_strates</div><div class="ttdef"><b>定义</b> <a href="#l00034">strategy.hpp:34</a></div></div>
<div class="ttc" id="anamespacestd_html"><div class="ttname"><a href="../../d8/dcc/namespacestd.html">std</a></div><div class="ttdef"><b>定义</b> <a href="../../d1/d92/mandarava_2event_8hpp_source.html#l00038">event.hpp:39</a></div></div>
<div class="ttc" id="anamespacewheels_html"><div class="ttname"><a href="../../df/d8d/namespacewheels.html">wheels</a></div><div class="ttdoc">堆栈信息读取和保存记录</div><div class="ttdef"><b>定义</b> <a href="../../d3/df7/ary__str_8hpp_source.html#l00006">ary_str.hpp:7</a></div></div>
<div class="ttc" id="astructwheels_1_1dm_1_1strategy_html"><div class="ttname"><a href="../../d0/db2/structwheels_1_1dm_1_1strategy.html">wheels::dm::strategy</a></div><div class="ttdef"><b>定义</b> <a href="#l00026">strategy.hpp:26</a></div></div>
</div><!-- fragment --></div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
制作者&#160;<a href="https://www.doxygen.org/index.html"><img class="footer" src="../../doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.11.0
</small></address>
</div><!-- doc-content -->
</body>
</html>
